package com.demo.dune.service.strategy;

/**
 * MemberStrategyConst.
 * @author Allen
 * @version 1.0 2022-04-04
 */
public class MemberStrategyConst {
	
	public static final String GOLD_MEM_STRATEGY = "GOLD_MEM_STRATEGY";
	
	public static final String SILVER_MEM_STRATEGY = "SILVER_MEM_STRATEGY";
	
	public static final String COPER_MEM_STRATEGY = "COPER_MEM_STRATEGY";
	
	/**
	 * getStrategyNameByMemType, memberType and Strategy are one to one relationships.
	 * @param memType
	 * @return StrategyName
	 */
    public static String getStrategyNameByMemType(String memType) {
		String strategyName = "";
		if (!MemberTypeEnum.isInclude(memType)) {
			return "";
		}
		if (MemberTypeEnum.GOLD.getCode().equals(memType)) {
			strategyName = MemberStrategyConst.GOLD_MEM_STRATEGY;
		} else if (MemberTypeEnum.SILVER.getCode().equals(memType)) {
			strategyName = MemberStrategyConst.SILVER_MEM_STRATEGY;
		} else if (MemberTypeEnum.COPER.getCode().equals(memType)) {
			strategyName = MemberStrategyConst.COPER_MEM_STRATEGY;
		}
		return strategyName;
    }

}
